<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title>全国4S店数据对比</title>
    <meta name="viewport" content="width=device-width,height=device-height,initial-scale=1.0,maximum-scale=1.0,user-scalable=no;">
    <link rel="stylesheet" type="text/css" href="view/iwocar5/css/main.css" />
</head>
<body>
    <div class="form-bar">
        <h3 class="pub-title">
            <span>集客量极限对比</span>
        </h3>
        <div class="form-border">
            <h3 class="form-title bar-title">
                <p>最大值/最小值</p>
            </h3>   
            <div class="dataAnalyze-form" id="dataAnalyze1-form1"></div>
        </div>
    </div> 
    <div class="form-bar">
        <h3 class="pub-title">
            <span>月销量极限对比</span>
        </h3>
        <div class="form-border">
            <h3 class="form-title bar-title">
                <p>最大值/最小值</p>
            </h3>   
            <div class="dataAnalyze-form" id="dataAnalyze1-form2"></div>
        </div>
    </div> 
    <div class="form-bar" style="display:none;">
        <h3 class="pub-title">
            <span>服务满意度极限对比</span>
        </h3>
        <div class="form-border">
            <h3 class="form-title bar-title">
                <p>最高值/最低值</p>
            </h3>   
            <div class="dataAnalyze-form" id="dataAnalyze1-form3"></div>
        </div>
    </div> 
    <div class="form-bar">
        <h3 class="pub-title">
            <span>销售员极限对比</span>
        </h3>
        <div class="form-border">
            <h3 class="form-title bar-title">
                <p>最大值/最小值</p>
            </h3>   
            <div class="dataAnalyze-form" id="dataAnalyze1-form4"></div>
        </div>
    </div> 
<script src="http://echarts.baidu.com/build/dist/echarts.js"></script>
    <script type="text/javascript">
        // 路径配置
        require.config({
            paths: {
                echarts: 'http://echarts.baidu.com/build/dist'
            }
        });
        
        // 使用
        require(
            [
                'echarts',
                'echarts/chart/bar' // 使用柱状图就加载bar模块，按需加载
            ],
            function (ec) {
                // 基于准备好的dom，初始化echarts图表
                var myChart = ec.init(document.getElementById('dataAnalyze1-form1')); 
                
                var option = {
                    calculable : false,
                    xAxis : [
                        {
                            type : 'category',
                            data : ['<?php echo $maxname?>','<?php echo $minname?>'],
                            axisLine: {lineStyle: {color: '#EEEEEE'}},
                            splitLine : {
                                show : false,
                            },
                        }
                    ],
                    yAxis : [
                        {
                            type : 'value',
                            scale : true,
                            axisLine: {lineStyle: {color: '#EEEEEE'}},
                        }
                    ],
                    series : [
                        {
                            // name:'蒸发量',
                            type:'bar',
                            barCategoryGap : '80%',
                            itemStyle: {
                                normal: {
                                    color: '#434c53',
                                    label : {
                                        show: true, position: 'top',
                                        textStyle:{
                                            color : '#000',
                                        }
                                    }
                                }
                            },
                            data:[<?php echo $maxjk?>,<?php echo $minjk?>]
                        }
                    ],
                    grid : {
                        x : '20%',
                        y : '15%',
                        x2 : '10%',
                        y2 : '20%'
                    }
                };
        
                // 为echarts对象加载数据 
                myChart.setOption(option); 
                window.onresize = myChart.resize;
            }
        );
        
        // 使用
        require(
            [
                'echarts',
                'echarts/chart/bar' // 使用柱状图就加载bar模块，按需加载
            ],
            function (ec) {
                // 基于准备好的dom，初始化echarts图表
                var myChart = ec.init(document.getElementById('dataAnalyze1-form2')); 
                
                var option = {
                    calculable : false,
                    xAxis : [
                        {
                            type : 'category',
                            data : ['北京博瑞祥星','北京博瑞祥星'],
                            axisLine: {lineStyle: {color: '#EEEEEE'}},
                            splitLine : {
                                show : false,
                            },
                        }
                    ],
                    yAxis : [
                        {
                            type : 'value',
                            scale : true,
                            axisLine: {lineStyle: {color: '#EEEEEE'}},
                        }
                    ],
                    series : [
                        {
                            // name:'蒸发量',
                            type:'bar',
                            barCategoryGap : '80%',
                            itemStyle: {
                                normal: {
                                    color: '#434c53',
                                    label : {
                                        show: true, position: 'top',
                                        textStyle:{
                                            color : '#000',
                                        }
                                    }
                                }
                            },
                            data:['0','0']
                        }
                    ],
                    grid : {
                        x : '20%',
                        y : '15%',
                        x2 : '10%',
                        y2 : '20%'
                    }
                };
        
                // 为echarts对象加载数据 
                myChart.setOption(option); 
                window.onresize = myChart.resize;
            }
        );
         // 使用
        require(
            [
                'echarts',
                'echarts/chart/bar' // 使用柱状图就加载bar模块，按需加载
            ],
            function (ec) {
                // 基于准备好的dom，初始化echarts图表
                var myChart = ec.init(document.getElementById('dataAnalyze1-form3')); 
                
                var option = {
                    calculable : false,
                    xAxis : [
                        {
                            type : 'category',
                            data : ['成都新元素','陕西奥诚'],
                            axisLine: {lineStyle: {color: '#EEEEEE'}},
                            splitLine : {
                                show : false,
                            },
                        }
                    ],
                    yAxis : [
                        {
                            type : 'value',
                            scale : true,
                            axisLine: {lineStyle: {color: '#EEEEEE'}},
                        }
                    ],
                    series : [
                        {
                            // name:'蒸发量',
                            type:'bar',
                            barCategoryGap : '80%',
                            itemStyle: {
                                normal: {
                                    color: '#434c53',
                                    label : {
                                        show: true, position: 'top',
                                        textStyle:{
                                            color : '#000',
                                        }
                                    }
                                }
                            },
                            data:[0,0]
                        }
                    ],
                    grid : {
                        x : '20%',
                        y : '15%',
                        x2 : '10%',
                        y2 : '20%'
                    }
                };
        
                // 为echarts对象加载数据 
                myChart.setOption(option); 
                window.onresize = myChart.resize;
            }
        );   
        // 使用
        require(
            [
                'echarts',
                'echarts/chart/bar' // 使用柱状图就加载bar模块，按需加载
            ],
            function (ec) {
                // 基于准备好的dom，初始化echarts图表
                var myChart = ec.init(document.getElementById('dataAnalyze1-form4')); 
                
                var option = {
                    calculable : false,
                    xAxis : [
                        {
                            type : 'category',
                            data : ['北京博瑞祥星','北京博瑞祥星'],
                            axisLine: {lineStyle: {color: '#EEEEEE'}},
                            splitLine : {
                                show : false,
                            },
                        }
                    ],
                    yAxis : [
                        {
                            type : 'value',
                            scale : true,
                            axisLine: {lineStyle: {color: '#EEEEEE'}},
                        }
                    ],
                    series : [
                        {
                            // name:'蒸发量',
                            type:'bar',
                            barCategoryGap : '80%',
                            itemStyle: {
                                normal: {
                                    color: '#434c53',
                                    label : {
                                        show: true, position: 'top',
                                        textStyle:{
                                            color : '#000',
                                        }
                                    }
                                }
                            },
                            data:['0','0']
                        }
                    ],
                    grid : {
                        x : '20%',
                        y : '15%',
                        x2 : '10%',
                        y2 : '20%'
                    }
                };
        
                // 为echarts对象加载数据 
                myChart.setOption(option); 
                window.onresize = myChart.resize;
            }
        );
</script>
</body>
</html>